iverilogfandomcom-20200214-history
Installation Guide
Icarus may be installed from source code or from pre-packaged binary distributions. __TOC__ = Installation From Source = Icarus is developed for Unix-like environments but can also be compiled on Windows systems using Cygwin environment or Mingw compilers. The following instructions are the common steps for obtaining the Icarus Verilog source, compiling and installing. Note that there ar precompiled and/or prepackages versions for a variety of systems, so if you find an appropriate packaged version, then that is the easiest way to install. Obtaining Snapshots The ftp site for the latest snapshot is ftp://ftp.icarus.com/pub/eda/verilog/snapshots. Download a tarball with a name such as verilog-version.tar.gz and un-tar it using: % tar -zxvf verilog-''version''.tar.gz This will create a directory, similar to the name of the tarball, such as verilog-version. Change into this directory using: % cd verilog-''version'' The source is then compiled and installed in the manner appropriate for you operating system. See below. Obtaining Source From CVS The source code for Icarus is stored under the CVS source code control system. At this point you have a choice to make. Decide if you want to get the latest development (main trunk) or if you want to get the latest of a specific branch. Stable releases are placed on branches, and in particular the v0.8 stable releases are on the branch "v0_8-branch" To get the development version of the code follow these steps: % cvs -d :pserver:cvs@icarus.com:/home/demon/anoncvs login (Password is "cvs") % cvs -d :pserver:cvs@icarus.com:/home/demon/anoncvs get verilog Or, to get the v0.8 stable branch, follow these steps: % cvs -d :pserver:cvs@icarus.com:/home/demon/anoncvs login (Password is "cvs") % cvs -d :pserver:cvs@icarus.com:/home/demon/anoncvs get verilog -r v0_8-branch This sequence (whichever you choose) will create a directory, named verilog, containing the source tree and will populate that directory with the most current source from the repository. Change into this directory using: % cd verilog The source tree may later be synched up with the development source by using the cvs. command: % cvs update -d (Note that you do not need to specify the branch name in the update command. CVS Remembers.) Configuration files are built by the extra step: % source autoconf.sh The source is then compiled as appropriate for your system. Compiling on Linux/Unix This is probably the easiest case. Given that you have the source tree from the above instructions, the compile and install is generally as simple as: % ./configure % make (su to root) # make install The "make install" typically needs to be done as root so that it can install in directories such as "/usr/local/bin" etc. You can change where you want to install by passing a prefix to the "configure" command: % ./configure --prefix=/my/special/directory This will configure the source for eventual installation in the directory that you specify. Note that "rpm" packages of binaries for Linux are typically configured with "--prefix=/usr" per the Linux File System Standard. Compiling on Macintosh OS X Since Mac OS X is a BSD flavor of Unix, you can install Icarus Verilog from source using the procedure described above. You need to install the Xcode software, which includes the C and C++ compilers for Mac OS X. The package is available for free download from Apple's developer site. Once Xcode is installed, you can build Icarus Verilog in a terminal window just like any other Unix install. Compiling on Solaris This section needs writing. Solaris is basically Linux/Unix, but there are tool options that confuse the issue. This needs to be written by someone who has appropriate systems and can test procedures. Compiling on M$ Windows The source as available above can also be compiled on MS Windows systems. The preferred method for compiling on Windows is to use the mingw32 compiler. The source tree has detailed instrutions for configuring/compiling in the text file "mingw.txt". Be warned, compiling for Windows is somewhat painful. Compiling on M$ Windows (cygwin) Cygwin users should preferably use the mingw32 method to compile Icarus Verilog. Programs compiled by mingw32 are perfectly useable under Cygwin, like any other Windows binary. However, there is occasionally reason to compile directly under Cygwin. In this case, in a Cygwin command line follow the instructions for Linux/Unix. The instructions are the same, as Cygwin is an attempt to be Unix under Windows. In order to compile/install icarus using cygwin the following packages have to be installed: binutils, g++, autoconf, automake, make, flex, bison, gperf, libbz2-devel (otherwise system.vpi won't build), ghostscript (to get ps2pdf) = Installation From Premade Packages = The various operation systems and distributions have various package management systems, and there are prepackaged distributions of Icarus Verilog available for some of them. If there is a prepackaged version that is suitable for your system and needs, then prepackaged installs are the easiest. RPM Based Systems On systems that use RPM Package Manager (RPM) software packages, Icarus Verilog may be installed from a binary RPM package. If no binary RPM package is available for your system, then one can be easily made from a source RPM package. Building a Binary RPM Package Source RPM packages are generally available at the same site where the source tarballs are hosted, and have the suffix ".src.rpm". Once downloaded, a binary RPM package can be built using: % rpmbuild --rebuild verilog-''version''.src.rpm (Older RPM Based Systems that do not have rpmbuild use rpm to build the binary packages.) This compiles the source RPM package and makes a binary RPM package tailored for your system. The generated package is placed where you configured rpm to place built packages: often "/usr/src/rpm/RPMS". (NOTE: Building packages may require that you include other packages (notably ''-devel'' packages) that are not otherwise needed.) Installing a Binary RPM Package Binary RPM packages, downloaded or built using the instructions above, can be installed with the following command (run as root): # rpm -Uvh verilog-''version''.type.rpm If you are using yum (Yellow dog Updater) as your RPM package updater/installer/remover, then you can install a downloaded or built binary RPM package with the following command (run as root): # yum -y localinstall verilog-''version''.type.rpm SuSE Linux/openSUSE Werner Hoch provides a "yum" repository with a variety of EDA packages, including the stable releases of Icarus Verilog and gtkwave. The easiest way to use this repository is via "YaST". * Start the YaST Control Center application, normally from your start menu. * Select "Installation Source" to add the new repository. * In the Installation Source control panel, select Add-->FTP to add a new FTP source. * The FTP server is ftp-1.gwdg.de * The Directory is one of these: ** /pub/opensuse/repositories/home:/werner2101/SUSE_Linux_9.3 ** /pub/opensuse/repositories/home:/werner2101/SUSE_Linux_10.0 ** /pub/opensuse/repositories/home:/werner2101/SUSE_Linux_10.1 * Click "OK" in the Add... dialog to add the repository, and * Click "Finish" to finish adding the installation source. Now you can use the YaST "Software Management" control to add the "verilog" package, which is Icarus Verilog. An alternate mirror of this repository is here: * The HTTP server is software.opensuse.org * The directory is one of these: ** /download/home:/werner2101/SUSE_Linux_9.3 ** /download/home:/werner2101/SUSE_Linux_10.0 ** /download/home:/werner2101/SUSE_Linux_10.1 Ubuntu Linux This needs testing! See discussion tab. The Ubuntu Universe repository has the Icarus Verilog .deb package. To install Icarus Verilog follow the steps below * Add the Universe repository in /etc/apt/sources.list using your favourite text editor (It would already be there but would have been commented). In Edgy Eft,the line would be something like deb http://archive.ubuntu.com/ubuntu/ edgy universe deb-src http://archive.ubuntu.com/ubuntu/ edgy universe * Run sudo apt-get update from terminal. * Run sudo apt-get install verilog Macintosh OS X Icarus Verilog can be easily installed on Mac OS using either the MacPorts or Fink package managers. MacPorts Instructions for downloading and installing MacPorts can be found here. Once MacPorts is installed and configured, Icarus Verilog can be installed in a terminal window using: % sudo port -d -v install iverilog GTKWave (the waveform viewer) can also be installed via MacPorts: % sudo port -v install gtkwave Fink Instructions for downloading and installing Fink can be found here. TBD Windows TBD.